﻿using System;
using System.Collections.Generic;
using System.Text;

namespace Utility.Net.WebService
{
        public class ExceptionStatus
        {
            public ExceptionStatus(ExceptionID id, string message)
            {
                this.ExceptionId = id;
                this.ExceptionMessage = message;
            }
            public ExceptionStatus()
            {
                this.ExceptionId = 0;
                this.ExceptionMessage = string.Empty;
            }

            private ExceptionID exceptionId;
            public ExceptionID ExceptionId
            {
                get
                {
                    return exceptionId;
                }
                set
                {
                    exceptionId = value;
                }
            }
            private string exceptionMessage;
            public string ExceptionMessage
            {
                get
                {
                    return exceptionMessage;
                }
                set
                {
                    exceptionMessage = value;
                }
            }
        }

        public enum ExceptionID
        {
            NEED_ACCEPTANCE,
            ACCEPTANCE_ADOPTED_TODAY,
            ACCEPTANCE_ADOPTED_FUTURE_DAY,
            EMAIL_ADDRESS_ERROR,
            FILE_ERROR_NOT_PDF,
            ERROR_SENDING_EMAIL,
            NO_RECORDS,

            OTHER
        }

        public interface IExcepionList
        {

        }

        public interface IRequestStatus
        {
            Status Status
            {
                get;
                set;
            }

        }

        [Serializable]
        public class RequestRaport : IRequestStatus, IExcepionList
        {

            private Status status;
            public Status Status
            {
                get
                {
                    return status;
                }
                set
                {
                    status = value;
                }
            }

            public ExceptionStatus[] requestExceptions;
        }

        public enum Status
        {
            OK,
            Warning,
            Error
        }
}
